#include "leftitemdelegate.h"

LeftItemDelegate::LeftItemDelegate(QObject *parent) :
  AbstractDelegate(parent)
{
}
int LeftItemDelegate::fontSize(const QRect &r) const
{
  return 22;
}

int LeftItemDelegate::leftMargin(const QRect &r) const
{
  return 33;
}

QBrush LeftItemDelegate::rectBrush(const QRect &r) const
{
  return Qt::transparent;
}

QBrush LeftItemDelegate::selectedRectBrush(const QRect &r) const
{
  return QColor(120,120,120,150);
}

QPen LeftItemDelegate::rectPen(const QRect &r) const
{
  QLinearGradient grad(r.topLeft(),r.topRight());
  grad.setColorAt(0,Qt::transparent);
  grad.setColorAt(0.45,QColor(120,120,120,150));
  grad.setColorAt(0.55,QColor(120,120,120,150));
  grad.setColorAt(1,Qt::transparent);
  return QPen(QBrush(grad),1);
}

QPen LeftItemDelegate::selectedRectPen(const QRect &r) const
{
  return QColor(90,90,90,150);
}

QPen LeftItemDelegate::textPen(const QRect &r) const
{
  return QColor(54,54,54);
}

QPen LeftItemDelegate::selectedTextPen(const QRect &r) const
{
  return QColor(250,250,250);
}

QPen LeftItemDelegate::disabledTextPen(const QRect &r) const
{
  return QColor(200,200,200);
}
